<?php
	class chucvubs
	{
		// Các trường
		public $MaChucVu = 0;
		public $TenChucVu = "";
		public $MaPhongBan = "";
		
		// Các phương thức
		public function Them()
		{
			$db = new chucvudb();
			return $db->Them($this->TenChucVu,
						     $this->MaPhongBan);
		}
		
		
		public function CapNhat()
		{
			$db = new chucvudb();
			return $db->CapNhat($this->MaChucVu, 
								$this->TenChucVu,
								$this->MaPhongBan);
		}
		
		public function TonTaiTrongNhanVien()
		{
			$db = new chucvudb();
			return $db->TonTaiTrongNhanVien($this->MaChucVu);
		}
		
		public function Xoa()
		{
			$db = new chucvudb();
			return $db->Xoa($this->MaChucVu);
		}
		
		public function XoaTatCa()
		{
			$db = new chucvudb();
			return $db->XoaTatCa();
		}
		
		public function LayDanhSach()
		{
			$db = new chucvudb();
			return $db->LayDanhSach($this->MaChucVu,
									$this->TenChucVu,
									$this->MaPhongBan);
		}
	}
?>